#define _CRT_SECURE_NO_WARNINGS
#include <stdio.h>

int main()
{
    int a, b, c, d;
    scanf("%d", &a);
    b = a / 100;
    c = a / 10 % 10;
    d = a - b * 100 - c * 10;
    printf("%d%d%d\n", d, c, b);

}
